import axios from '@/libs/request'

/**
 * 统计管理
 */
// 场所统计
export const getDayAllNum = (data) => {
  return axios.request({
    url: '/api/uc/ctc/ctcUserPermitService/getDayAllNum',
    data: data,
    type: 'post'
  })
}
// 场所扫描统计
export const searchQrCodeUserState = (data) => {
  return axios.request({
    url: 'wl/api/searchQrCodeUserState',
    data: data,
    type: 'post',
    php: true
  })
}

/**
 * 办理管理
 */

// 办理列表
export const getHandleList = (data) => {
  return axios.request({
    url: '/api/as/ctcm/handle/getHandleList',
    data: data,
    type: 'post'
  })
}
// 办理删除
export const deleteHandle = (data) => {
  return axios.request({
    url: '/api/as/ctcm/handle/deleteHandle',
    data: data,
    type: 'post'
  })
}
// 办理修改
export const updateHandleInfo = (data) => {
  return axios.request({
    url: '/api/as/ctcm/handle/updateHandleInfo',
    data: data,
    type: 'post'
  })
}
/**
 * 场所管理
 */

// 统计
export const getPlaceCount = (data) => {
  return axios.request({
    url: '/api/ac/ctcm/workerPermitService/getPlaceCount',
    data: data,
    type: 'post'
  })
}
// 场所列表
export const getPeopleList = (data) => {
  return axios.request({
    url: '/api/as/ctcm/place/getPlaceList',
    data: data,
    type: 'post'
  })
}
// 二维码统计
export const companyCodeQrCodeStatistics = (data) => {
  return axios.request({
    url: 'wl/api/companyCodeQrCodeStatistics',
    data: data,
    type: 'post',
    php: true,
    await: true
  }).catch(e => {
    console.log('报错了', e)
  })
}
// 删除场所
export const deletePlace = (data) => {
  return axios.request({
    url: '/api/as/ctcm/place/deletePlace',
    data: data,
    type: 'post'
  })
}
// 修改二维码地址
export const updatePlaceURL = (data) => {
  return axios.request({
    url: '/api/as/ctcm/place/updatePlaceURL',
    data: data,
    type: 'post'
  })
}
// 修改场所
export const updatePlaceInfo = (data) => {
  return axios.request({
    url: '/api/as/ctcm/place/updatePlaceInfo',
    data: data,
    type: 'post'
  })
}
// 查看场所重复人员数据
export const searchRepeatUserState = (data) => {
  return axios.request({
    url: 'wl/searchRepeatUserState',
    data: data,
    type: 'post'
  })
}
// 获取二维码
export const userStrToQrcode = (data) => {
  return axios.request({
    url: '/wl/userStrToQrcode',
    data: data,
    type: 'post'
  })
}
// 对比公安库
export const selectGongAnInfo = (data) => {
  return axios.request({
    url: '/wl/dc/selectGongAnInfo',
    data: data,
    type: 'post'
  })
}
// 查询沈阳殡葬
export const binZhang = (data) => {
  return axios.request({
    url: 'wl/dc/binZhang',
    data: data,
    type: 'post'
  })
}
// 获取二维码
export const getTotalCount = (data) => {
  return axios.request({
    url: '/wl/tj/getTotalCount',
    data: data,
    type: 'post',
    php: true,
    await: true
  })
}
// 绑定人员列表
export const findPlacePersonList = (data) => {
  return axios.request({
    url: '/api/as/ctcm/place/findPlacePersonList',
    data: data,
    type: 'post'
  })
}
// 保存绑定人员
export const insertPlacePerson = (data) => {
  return axios.request({
    url: '/api/as/ctcm/place/insertPlacePerson',
    data: data,
    type: 'post'
  })
}
// 删除绑定人员
export const updatePlaceInfoPerson = (data) => {
  return axios.request({
    url: '/api/as/ctcm/place/updatePlaceInfoPerson',
    data: data,
    type: 'post'
  })
}
// 根据身份证号获取人员信息
export const customerSearchUser = (data) => {
  return axios.request({
    url: '/wl/api/customerSearchUser',
    data: data,
    type: 'post',
    php: true
  })
}
// 查看复核信息
export const findRecheckList = (data) => {
  return axios.request({
    url: '/api/as/ctcm/permit/findRecheckList',
    data: data,
    type: 'post',
    php: true
  })
}
// 查看复核信息2
export const findRecheckListNew = (data) => {
  return axios.request({
    url: '/wl/api/selectFuCha',
    data: data,
    type: 'get',
    php: true
  })
}
// 查看机构下拉列表
export const findOfficeXJList = (data) => {
  return axios.request({
    // url: '/api/as/sc/office/findOfficeXJList',
    url: '/api/ac/sc/office/getList',
    data: data,
    type: 'post'
  })
}
// 统计机构所有场所数量
export const officePlaceNum = (data) => {
  return axios.request({
    url: '/api/ac/ctcm/PlaceServiceImpl/officePlaceNum',
    data: data,
    type: 'post'
  })
}
// 批量删除
export const deletePlacePL = (data) => {
  return axios.request({
    url: '/api/as/ctcm/place/deletePlacePL',
    data: data,
    type: 'post'
  })
}
// 全部替换编号二维码
export const rebootCreateQrCode = (data) => {
  return axios.request({
    url: '/wl/api/rebootCreateQrCode',
    data: data,
    php: true,
    type: 'post'
  })
}
